<!DOCTYPE html>
<html>

<head>
    <meta charset='UTF-8'>
    <meta name='viewport' content='width=device-width,initial-scale=1.0'>
    <meta http-equiv='X-UA-Compatible' content='ie=edge'>
    <title>Document</title>
</head>

<body>
    <div id='app'>
        <!-- v-bind 绑定style
        1.对象语法
            css属性名 可以是驼峰标识或者短横线连接(不要忘记单引号'font-size')
        2. 数组语法
        -->

        <!-- <p :style="{color:a,fontSize:b}">内容</p> -->
        <!-- <p :style="{color:a,'font-size':b}">内容</p> -->
        <!-- <div :style="styleObject">内容</div> -->
        <!-- <div :style="[x, y]">内容</div> -->


    </div>
    <script src='./vue.js'></script>
    <script>
        new Vue({
            el: '#app',
            data: {
                x: {
                    color: 'red'
                },
                y: {
                    'font-size': '30px'
                },

                styleObject: {
                    color: 'red',
                    'font-size': '13px'
                },
                a: 'red',
                b: '30px'
            },
            methods: {

            }
        });
    </script>
</body>

</html>